#include <iostream>
#include <fstream>
#include <sstream>
#include "freefuncs.h"
#include "rulebase.h"
#include <string>
#include "singlestep.h"
#include "longinstance.h"
#include "ruletangle2.h"
#include "bitmap.h"

/**
 * This test function is to test the operation of Ruletangle class. 
 * It manually creates two conflicting rule (i.e. LongInstance)
 * and adds the coordinates to each, so that the Ruletangle created
 * from those conflicting longinstances has to create rectangle2 
 * objects to store all the information correctly.
 */
void testRuletangle (void);

/**
 * This test function tries several functions to convert from bitmap files
 * into text files and then reads the output text files to re-create the 
 * images for visual comparison.
 */
void testTXT2BMP (void);

/**
 * Tests constructing an EightLayerIM object from a bitmap.
 * Also creates another EightLayerIM and constructs a RuleBase
 * from it's bit 0 to bit 1.
 */
void testELfromBMP (void);

/** Creates a SingleStep object and verifies it's apply() function. */
void testSingleStep (void);